package com.lanxin.controller;

import com.alibaba.dubbo.config.annotation.Reference;
import com.lanxin.UserService;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/user")
public class UserController {

    @Reference(group = "group2",cluster = "failfast",timeout = 500)
    private UserService userService;

    //返回值
    @RequestMapping("/hello")
    public String hello(){
        return userService.say("张三");
    }
}
